<?php

/**
 * SfGuardUserProfile form.
 *
 * @package    tercermilenio
 * @subpackage form
 * @author     Your name here
 */
class SfGuardUserProfileForm extends BaseSfGuardUserProfileForm {

    public function configure() {

    }

    public function setup() {

        parent::setup();

        $this->setWidgets(array(
            'id' => new sfWidgetFormInputHidden(),
            'usr_id' => new sfWidgetFormInput(),
            'telefono_1' => new sfWidgetFormInput(),
            'telefono_2' => new sfWidgetFormInput(),
            'tipo_doc' => new sfWidgetFormInput(),
            'nro_doc' => new sfWidgetFormInput(),
            'direccion' => new sfWidgetFormInput(),
        ));

        $this->setValidators(array(
            'id' => new sfValidatorPropelChoice(array('model' => 'SfGuardUserProfile', 'column' => 'id', 'required' => false)),
            'usr_id' => new sfValidatorInteger(array('required' => false)),
            'telefono_1' => new sfValidatorString(array('max_length' => 50, 'required' => false)),
            'telefono_2' => new sfValidatorString(array('max_length' => 50, 'required' => false)),
            'tipo_doc' => new sfValidatorInteger(array('required' => false)),
            'nro_doc' => new sfValidatorInteger(array('required' => false)),
            'direccion' => new sfValidatorString(array('max_length' => 100, 'required' => false)),
        ));

        $this->widgetSchema->setNameFormat('sf_guard_user_profile[%s]');

        $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);
    }

}
